import store from "@/store/index"
import { getModule, Module, Mutation, VuexModule } from "vuex-module-decorators"
@Module({ dynamic: true, namespaced: true, store, name: "menu" })
class Menu extends VuexModule {
  private menuTree = []

  get getMenuTree() {
    return this.menuTree
  }

  @Mutation
  commitAddMenuTree(menuList: never[]) {
    this.menuTree = menuList
  }
}

export { Menu }
export const menuStore = getModule<Menu>(Menu)
